<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	  xmlns:ui="http://java.sun.com/jsf/facelets"
	  xmlns:h="http://java.sun.com/jsf/html"
	  xmlns:s="http://jboss.org/schema/seam/taglib">

<head>
	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
	<title>Seam Remoting - Hello World Example</title>
</head>

<body>

  <h1>Seam Remoting - Hello World Example</h1>
  
  <p>
  
  </p>

  <s:remote include="helloAction"/>
  
  <script type="text/javascript">    
    function sayHello() {
      var name = prompt("What is your name?");
      if (name == null) return;
      var callback = function(result) { alert(result); };
      Seam.Component.getInstance("helloAction").sayHello(name, callback);
    }
  </script>  

  <button onclick="javascript:sayHello()">Say Hello</button>

</body>
</html>

